using UnityEngine;

public class NewMainMenuManager : MonoBehaviour
{
	public enum MainMenuStates
	{
		None,
		Title,
		Console,
		Hypothetical,
		Logs,
		Credits,
		Extras
	}

	public static NewMainMenuManager instance;

	[SerializeField]
	private GameObject FogCylinder;

	[SerializeField]
	private Light globalLight;

	public Animator CameraAnimator;

	public AudioSource MenuSource;

	public AudioClip SFX_MenuSelect;

	public AudioClip SFX_MenuMove;

	public AudioClip SFX_MenuDeny;

	public AudioClip SFX_MenuClick;

	public AudioClip SFX_ComputerBootOff;

	[SerializeField]
	private GameObject TitleMenu;

	[SerializeField]
	private GameObject ConsoleMenu;

	[SerializeField]
	private GameObject HypotheticalMenu;

	[SerializeField]
	private GameObject LogMenu;

	[SerializeField]
	private GameObject CreditMenu;

	[SerializeField]
	private GameObject ExtraMenu;

	private void Awake()
	{
		instance = this;
	}

	private void Start()
	{
		if (SettingsManager.Instance.GetBoolSettingValue("SimpleVFX"))
		{
			Object.Destroy((Object)(object)FogCylinder);
			globalLight.shadows = (LightShadows)0;
		}
		UI_LoadingIcon.ToggleLoadingIcon(showIcon: false);
		GonerMenu.CurrentActiveHypothesis = null;
		GonerMenu.RecoveringFromGameOver = false;
		PartyMemberSystem.Instance.RemoveAllPartyMember();
		PlayerPrefs.SetInt("TimesPlayed", PlayerPrefs.GetInt("TimesPlayed", 0) + 1);
	}

	public void SetMainMenuState(MainMenuStates state)
	{
		switch (state)
		{
		case MainMenuStates.Console:
			TitleMenu.SetActive(false);
			ConsoleMenu.SetActive(true);
			CameraAnimator.Play("MainMenu_Camera_MonitorIdle");
			break;
		case MainMenuStates.Hypothetical:
			TitleMenu.SetActive(false);
			HypotheticalMenu.SetActive(true);
			CameraAnimator.Play("MainMenu_Camera_MonitorIdle");
			break;
		case MainMenuStates.Title:
			break;
		}
	}
}
